<div id="sidebar">
	<ul>

		<li id="blog-search">
			<h2><label for="s">Search</label></h2>
			<?php include (TEMPLATEPATH . '/searchform.php'); ?>
		</li>

		<?php wp_list_pages('title_li=<h2>Contents</h2>' ); ?>

		<li id="blog-categories">
			<h2>Categories</h2>
			<ul>
				<?php wp_list_cats('sort_column=name&hierarchical=1'); ?>
			</ul>
		</li>

		<li id="blog-archives">
			<h2>Archives</h2>
			<ul>
				<?php wp_get_archives('type=monthly'); ?>
			</ul>
		</li>

		<?php if ( is_home() || is_page() ) { ?>

			<?php get_links_list('id-'); ?>

			<li id="feeds">
				<h2>XML Feeds</h2>
				<ul>
					<li><a href="<?php bloginfo('atom_url'); ?>" title="<?php bloginfo('name'); ?> Atom 1.0 (XML) Feed" rel="alternate" type="application/atom+xml">Atom Feed</a></li>
					<li><a href="<?php bloginfo('rss2_url'); ?>" title="<?php bloginfo('name'); ?> RSS 2.0 (XML) Feed" rel="alternate" type="application/rss+xml">RSS Feed</a></li>
					<li><a href="<?php bloginfo('comments_rss2_url'); ?>" title="<?php bloginfo('name'); ?> Comments RSS 2.0 (XML) Feed" rel="alternate" type="application/rss+xml">Comments RSS Feed</a></li>
				</ul>
			</li>

			<li id="meta">
				<h2>Meta</h2>
				<ul>
					<?php wp_register(); ?>
					<li><?php wp_loginout(); ?></li>
					<li><a href="http://wordpress.org/" title="Powered by WordPress">WordPress</a></li>
					<?php wp_meta(); ?>
				</ul>
			</li>

		<?php } ?>

	</ul>
</div><!-- END SIDEBAR -->